//
//  ViewController.m
//  LastOne
//
//  Created by dllo on 15/11/3.
//  Copyright © 2015年 sc. All rights reserved.
//

#import "ViewController.h"
#import "NightHeader.h"
#import "Music.h"
@interface ViewController ()
@property(nonatomic, strong)UILabel *label;
@property(nonatomic, strong)UIButton *button;
@end

@implementation ViewController

- (void)viewWillAppear:(BOOL)animated
{
    [super viewWillAppear:YES];
    [self.navigationController.navigationBar NightWithType:UIViewColorType1];
    [self.tabBarController.tabBar NightWithType:UIViewColorTypeNormal];
    //改变nav字体颜色
    [self.navigationController.navigationBar setTitleTextAttributes:[NSMutableDictionary dictionaryWithObjectsAndKeys:[UIColor whiteColor], NSForegroundColorAttributeName, nil]];
    
    //不透明
    self.navigationController.navigationBar.translucent = NO;
    
    //此法的只有在设置了以下代码才会被调用（对于preferredStatusBarStyle不执行问题）
    [self.navigationController.navigationBar setBarStyle:UIBarStyleBlack];
    
    self.tabBarController.tabBar.translucent = NO;
    
}
- (void)viewDidLoad {
    [super viewDidLoad]; 
}

#pragma mark 改变状态栏的颜色
-(UIStatusBarStyle)preferredStatusBarStyle
{
    return 3;
}


- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
